# -*- coding: utf-8 -*-
# @Time : 2023/12/15 22:01
# @Author : Z
# @Email : 1473858993@qq.com
# @File : parame_util.py
# @Project : apitwo
import os.path

import yaml

from common.dir import yaml_dir


def read_yaml_dict(filename):
    # 进行路径拼接
    filepath = os.path.join(yaml_dir, filename)
    # 打开yaml文件 #
    file = open(filepath, 'r+', encoding='utf8')
    # 读取yaml文件
    data = yaml.safe_load(file.read())
    # 返回yaml数据
    return data
